Map Editing
To create a map in Glest you will need to download the Glest Tools at Sourceforge Download Map Overview Maps are single files, that define bi-dimensional matrices of cells, each cell has the following attributes: *Height. From 0 to 20 *Surface type. There are 5 surface types, and the map editor numbering system indicates the texture type, the texture file itself depends on the tileset. *Object. A cell can have an object or not, there are 10 types of objects, object models depend on the tileset, but in general terms, objects 1 and 2 are trees, 3 is stone, 4 and 5 are bushes, objects from 6 to 9 can be anything and 10 is an invisible blocking object. *Resource. Resources can be placed on cells. objects and resources cannot share the same cell at the same time. Resources depend on the Tech Tree. Maps also define some other things such as start locations for each player, map size, altitude factor, and water level. Maps cannot define the placement of units or buildings. To play maps created with the editor, just place the .gbm file into the Glest directory map folder. Introduction to the Editor Glest Map Editor is the default map editor for Glest - the free, open-source, 3D real-time strategy game. Glest Map Editor allows users to define: *Map dimensions *Surface height *Surface type *Object location *Resource location *Number of players *Player and computer faction starting points *Other significant parameters Note: the map editor cannot define unit or building placements, the reason for this is that a map can be played with various tech trees with different unit and building types. Editor Window Single window properties *Top':' Menu Bar *Center-Left':' Map Display *Right':' Tool Bar *Bottom':' Info Label Map Display Map display reflects the current state of the map The map is divided into cells, each cell has a state: height, surface type, object type and resource type. The way the map reflects the state of the cells is as follows: *The big 'X' show the location of each player starting point. *Intensity of color reflects height(elevation). **the darker the color is, the lower the height of the cell. **the lighter the color is, the higher the height of the cell. *Color reflects the surface type: **Light green':' surface - 1 **Dark green':' surface - 2 **Brown':' surface - 3 **Gray':' surface - 4 **Red':' surface - 5 *An 'X' means that there is a resource on the cell, the color of the 'X' indicates the resource type. *An inverted 'L' means there is an object on the cell, the color of the inverted 'L', indicates the object type. Note':' Objects and resources cannot share the same cell. Users may interact with the map as follows':' *Left clicking over the map or to move the mouse while pressing left button modifies the map. *Moving the mouse while pressing the right mouse button scrolls the users viewing location on the map. *Moving the mouse while pressing the center button or shift+right mouse button zooms the map view. Toolbar The toolbar defines the way the map is modified when left clicking on the map display. Depending on the selected radio button, users may edit height, surface type, object type, resource type or starting points. *Radius':' The radius combo box is always available and indicates the number of cells modified when editing the map, a radius of one modifies only one cell, a higher radius modified more cells. *Height':' When height radio button is selected, users can alter the map surface height. (radius and height combo boxes modify the surface in different ways) *Starting Points':' Each player requires one starting point, this point is the map location where the initial buildings and units are placed. If there is not enough space at the starting point to place all units and buildings, an error will occur and the game will not load. *Surface':' When the surface radio button is selected, users can edit map surface type(s). Surface texture types vary between individual tilesets, but the default settings are: **Surface':' 1 - grass **Surface':' 2 - secondary grass **Surface':' 3 - road **Surface':' 4 - stone **Surface':' 5 - custom undefined *Object':' When the object radio button is selected, users can place objects on the map cells. Objects depend on the tileset, but the default settings are: **Object':' 0 - undefined undefined **Object':' 1 - tree walkable(false) -- wood resource type **Object':' 2 - dead tree walkable(false) **Object':' 3 - stones walkable(false) **Object':' 4 - bush walkable(true) **Object':' 5 - water object walkable(true) **Object':' 6 - Custom1 - dead tree walkable(false) **Object':' 7 - Custom2 - hanged/impaled/caged walkable(false)-- random model placement **Object':' 8 - Custom3 - obelisk/statue/broken statue walkable(false)--(random model placement) **Object':' 9 - Custom4 - large mossy rock/big stone walkable(false) **Object':' 10 -Custom5 - Invisible object walkable(false) *Resource: When the resource radio button is selected, users can place resources on a map cell. Resource types depend on the tech tree selected, but the default settings are: **custom':' 0 - undefined **Custom':' 1 - gold walkable(false) **Custom':' 2 - stone walkable(false) **Custom':' 3 - undefined **Custom':' 4 - undefined **Custom':' 5 - undefined *Note':' Tech trees can use objects as resources. The difference is that 3d models for objects are defined on the tileset while resource 3d models are defined on the tech tree. *Note':' undefined refers to the resource, object and surface texture settings used in most user created faction and tileset modification files. *Note':' walkable(false) *Note':' walkable(true) Menu Bar *File *Load: loads the selected map file. *Save and Save As: saves a map file. *Exit: closes the editor. *Edit *Reset: resets the map, users can specify map dimensions, default altitude and surface types. *Reset Players: changes the number of players on the map and resets starting points. *Info: here is where users enter the authors name, title and description of the map. *Advanced: two parameters can be edited here, altitudeFactor and waterLevel. **Altitude factor is a number that divides altitudes when surface is drawn in the game. It defaults to 3, that means that a cell that has an altitude of x, will have a real altitude of x/3 when rendered. **Water level is the altitude of the water in the game, note that units can walk over every cell that has a an altitude greater or equal to waterLevel-1. **Note: waterLevel is also divided by altitudeFactor. *Misc *Reset zoom and pos: resets zoom and position to the default values. *About: displays the copyright notice. *Mouse buttons: brief explanation of mouse functionality when interacting with the map. *Info label: here are displayed some parameters of the map. General Map Design Information Below is a list of guidelines written for users who are new to the Glest map making process. *Player and Resource Placement':' **At least 10 tiles (cells) of gold, stone and wood (trees) at the player starting point locations, and at least one smaller 5 tile(cells) resource area nearby **Generic four player maps space player and AI faction starting locations equidistantly **Multiplayer maps differ from generic maps and place allies closer together, and those allies may also share gold and stone resource sites. *Road and Trail Systems':' **Roads connect all player start locations **Roads should be at least five tiles (cells) wide. **Trails and paths connect to roads and usually lead to resource locations. Paths also provide an easy route through dense forests or across large, non descript, plains and deserts. **Trails and paths should be three tiles (cells) wide. Trails through dense forests - with a width of only two tiles(cells) - may trap size3 AI faction units and cause unit stacking and grid-locking. *Rivers, lakes and oceans':' *Map Objects':' **Place objects where logical. Trees rarely grow in rivers and lakes although a few dead tree objects in a pond can be visually appealing. **Statue and gallows objects should be used infrequently. Both look good at trail intersection points and on isolated islands. **Bushes look great in forests and along riverbanks - use them often. **Small stones look good but use them sparingly and in appropriate locations. IE: player starting locations are an inappropriate stone object placement location **Mossy Rocks/Big Rocks need to be surrounded with the pink colored invisible blocking 10-C5 object to prevent units from walking inside the rock model(s) *Surface texture types **surface 1 is normally light-colored green grass with random flower and weed texture patterns. **surface 2 is normally dark-colored green grass with no flower and weed texture patterns. **surface 3 is normally brown dirt or tan sand with random pebble and weed texture patterns. **surface 4 is normally composed of gray cobblestones, bricks, interlocking stone-tile and rock-gravel texture patterns **surface texture 5 is normally undefined and is rarely used on maps. *Surface texture uses':' **surface textures vary greatly between tilesets but in general: ***surface textures 1 and 2 are used as the primary surface type for meadows, mountains, plains, hills and valleys ***surface textures 3 and 4 are used for roads, trails, as ocean and lake shorelines and at player starting locations ***surface texture 5 is normally undefined and is rarely used on maps. General Map Design Tips Map making is tedious and boring so don't expect to knock out a map in an hour. Work on a map a few times a week with the ultimate goal of having a completed map ready after 15 days. *Is there enough room for building expansion at each of the starting locations? **The ultra AI typically constructs at least 12 buildings around the starting point which may lead to unit movement congestion. *Resource node location placement? **Ensure AI units do not become stuck between buildings and nodes while harvesting in large groups. **Placing blocking objects next to resources nodes may lead to unit stacking * AI Pathfinding on long routes? **Can the AI find the hostile base or group of hostiles? or does it get stuck on a path in a forest or around a lake or river? *Is the pathing at least 3 tiles (cells) wide at chokepoints? **Entry and exit trails and roads near the player starting points tend to be narrow to accommodate defensive oriented gamers. *Trails and roads? **Do roads and trails follow the natural geography of the map? **Do trails lead to resources or connect to other trails and roads? Please, no dead-end roads and trails. *Swamps and flooded regions **Proper height settings will trigger water splash animations and particles. This effect is quite pleasing, use it wisely. *Topography **Roads should be a couple units lower than the rest of the map, and only two units above the water, so that the river heights will look natural at road/water crossing points. **Maps with little change in elevation are uninteresting and require increased object placement to balance the flat, visually unappealing, terrain. *Game world visual appeal? **No one enjoys running around in a barren game world - place lots of objects on the map **Fifteen statues or nine stones in one location makes no sense and looks bad. **Does the map look good at various locations and from different viewing perspectives? **Do placed objects enhance the organic feel of the map? **Do the hills, valley's, mountains appear natural? **Do Lakes connect with rivers? **Are lakes and rivers bordered by dirt or sand? Remember to put shorelines around bodies of water **Stone roads look better if they are trimmed/bordered by dirt or sand shoulders. Image Reference (incomplete) http://images2.wikia.nocookie.net/glest/images/2/25/Th_samplemap.jpg map editor basic elements http://images3.wikia.nocookie.net/glest/images/f/f9/Th_samplemapGAE-1.jpg game view of the map editor basic elements Design Tricks and Glest AI Pathfinding Limitations (incomplete) visual enhancements while conforming to the AI pathfinder rules http://images1.wikia.nocookie.net/glest/images/1/12/Th_definedparameters.jpg *Draw diagonal perimeter lines on a map using the pink colored invisible walkable(false)-- blocking object 10-C5 **Create the map world within the predefined perimeter boundaries. http://images3.wikia.nocookie.net/glest/images/4/45/Map_guide_elements.jpg *Now place objects outside the perimeter of the ground unit (walkable) playfield - ground units cannot travel in these areas. This technique enhances the visual appearance of the game world. **Yellow highlighted areas are the walkable(false) portion of the map.note the pink blocking C5 pixel perimeter surrounding the walkable(false) map area **Blue lines are the original parameter requirements. **Red square is where the AI unit pathfinder fails. The map breaks the perimeter rule. **Red lines indicate the path on which the AI wants to travel - but cannot - due to performance failures with the Glest AI pathfinder coding. http://images1.wikia.nocookie.net/glest/images/b/b5/Guide_yellowcircle_pathing.jpg Game view of the map editor image seen above walkable(false)-- blocking object portion of the map. Our Wikia *Glest Tools *Objects